//===============================================================================
// Microsoft patterns & practices Enterprise Library Contribution
// Data Access Application Block
//===============================================================================

using System;
using System.Data.Common;
using Microsoft.Practices.EnterpriseLibrary.Common.Configuration.Unity;
using Microsoft.Practices.EnterpriseLibrary.Data;
using Microsoft.Practices.EnterpriseLibrary.Data.Configuration;
using EntLibContrib.Data.SQLite.Configuration.Unity;
using System.Data.SQLite;

namespace EntLibContrib.Data.SQLite
{
	/// <summary>
	/// Represents a SQLite database.
	/// </summary>
	/// <remarks>Internally uses SQLite .NET Provider to connect to the database.</remarks>
	[DatabaseAssembler(typeof(SQLiteDatabaseAssembler))]
	[ContainerPolicyCreator(typeof(SQLiteDatabasePolicyCreator))]
	public class SQLiteDatabase : Database
	{
		#region Construction
		/// <summary>
		/// Initializes a new instance of the SQLiteDatabase class.
		/// </summary>
		/// <param name="connectionString">The connection string.</param>
		public SQLiteDatabase(string connectionString)
			: base(connectionString, SQLiteFactory.Instance)
		{
		}
		#endregion

		#region Public Methods
		/// <summary>
		/// Retrieves parameter information from the stored procedure specified in the <see cref="SQLiteCommand"/> and populates the Parameters collection of the specified <see cref="SQLiteCommand"/> object.
		/// </summary>
		/// <param name="discoveryCommand">The <see cref="SQLiteCommand"/> to do the discovery.</param>
		protected override void DeriveParameters(DbCommand discoveryCommand)
		{
			throw new NotImplementedException("The method or operation is not implemented.");
		}
		#endregion
	}
}
